import BuffUtil from '@/BuffUtil';
import UnitSpellEvent from '@/event/UnitSpellEvent';
export default class Item_英勇面具 {
    static id = 'AIxk';
    static 名称: string = '英勇面具';
    static 描述: string = '增加80攻速与80法强，但是受到的伤害增加40%';
    static 图标: string = 'ReplaceableTextures\\CommandButtons\\BTNHelmOfValor.blp';
    static buffId: string = 'buff_item_yingyong';
    static buffType: AppBuffType = {
        id: 'buff_item_yingyong',
        name: Item_英勇面具.名称,
        ubertip: Item_英勇面具.描述,
        art: Item_英勇面具.图标,
        attribute: {
            attackSpd_p: 0.8,
            法术强度: 80,
            全伤害减免: -0.4,
        },
        dur: 12,
        targetArt: 'Abilities\\Spells\\Orc\\TrollBerserk\\HeadhunterWEAPONSLeft.mdl',
        targetAttach: 'weapon',
    };
    static 添加技能(目标: unit) {
        UnitAddAbility(目标, Item_英勇面具.id);
    }
    static 释放(x: number, y: number, 来源?: unit, 目标?: unit, d?: any) {
        BuffUtil.addBuff(来源, Item_英勇面具.buffId, 来源);
    }
    constructor() {
        BuffUtil.registerBuffType(Item_英勇面具.buffType);
        se.onUnitSpellEffect(Item_英勇面具.spellEffect, Item_英勇面具.id);
    }
    static spellEffect(this: void, d: UnitSpellEvent) {
        Item_英勇面具.释放(d.spellTargetX, d.spellTargetY, d.trigUnit, d.spellTargetUnit, d);
    }
}
